/**
 * Copyright © 2021-2025 <a href="http://www.jeeplus.org/">JeePlus</a> All rights reserved.
 */
package com.jeeplus.appointment.service.dto;

import com.alibaba.excel.annotation.ExcelProperty;
import com.baomidou.mybatisplus.annotation.TableField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.jeeplus.core.excel.annotation.ExcelDictProperty;
import com.jeeplus.core.excel.converter.ExcelDictDTOConverter;
import com.jeeplus.core.excel.converter.ExcelUserDTOConverter;
import com.jeeplus.core.query.Query;
import com.jeeplus.core.query.QueryType;
import com.jeeplus.core.service.dto.BaseDTO;
import com.jeeplus.doctor.domain.DoctorInfo;
import com.jeeplus.patient.domain.PatientInfo;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;
/**
 * 预约信息DTO
 * @author xx
 * @version 2023-12-30
 */
@Data
@EqualsAndHashCode(callSuper = false)
public class AppointmentInfoDTO extends BaseDTO {

	private static final long serialVersionUID = 1L;

	        
	/**
     * 病人id
     */
    @Query(tableColumn = "a.patient_id", javaField = "patientId", type = QueryType.EQ)
    @ExcelProperty(value = "病人id", converter = ExcelUserDTOConverter.class) 
	private String patientId;
	        
	/**
     * 医生id
     */
    @Query(tableColumn = "a.doctor_id", javaField = "doctorId", type = QueryType.EQ)
    @ExcelProperty(value = "医生id", converter = ExcelUserDTOConverter.class) 
	private String doctorId;
	        
	/**
     * 预约时间
     */
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	@ExcelProperty("预约时间") 
	private Date appointmentTime;
	        
	/**
     * 预约科室
     */
    @ExcelProperty(value = "预约科室")
	private String departmentId;
	        
	/**
     * 预约状态
     */
	@ExcelProperty(value = "预约状态", converter = ExcelDictDTOConverter.class)
	@ExcelDictProperty("application_state")
	private String appointmentStatus;

	@TableField(exist = false)
	private PatientInfo patientInfo;
	@TableField(exist = false)
	private DoctorInfo doctorInfo;

}
